﻿<?php
	require("conexao.php");
	
?>
<body>

<div id="main">
<div id="info">  
	<div id="log">
		Usuário: 
	        <span class="usuario">
           <?php
			if (!isset($_SESSION["user"]["LOGIN"])){ echo "Não Logado";} else { echo $_SESSION["user"]["NOME"];}
			?>
            </span>
		Hoje é:			
			<?php
			$dia_da_semana = array ("Domingo", "Segunda", "Terça", "Quarta", "Quinta", "Sexta", "Sábado");
			$num_dia = date("w");	
			$dia_extenso = $dia_da_semana[$num_dia];
			echo  $dia_extenso." ,".date("d/m/Y");
		    ?>
        - Hora:
            <?php
			echo date("H:i");
			?>
	</div>
</div>
<div class="top_top"></div>
<div id="header">
	
	<div id="buttons">
      <a href="index2.php?link=4" class="but but_t"  title="">Home</a><div class="but_razd"></div>      
      <?php if (isset($_SESSION["user"]["LOGIN"])){ ?>
       <a href="index2.php?link=8"  class="but" title="">Sair</a><div class="but_razd"></div>
       <?php } else { ?>
      <a href="index2.php?link=7"  class="but" title="">Entrar</a><div class="but_razd"></div>
      <?php } ?>
	  <a href="index2.php?link=5" class="but" title="">Administrativo</a><div class="but_razd"></div>
      <a href="index2.php?link=6"  class="but" title="">Meu Cadastro</a><div class="but_razd"></div>
      <a href="index2.php?link=#" class="but" title="">Fale Conosco</a>
    </div>
	<div id="logo">
    	</div>
   </div>

            </ul>
        </div>
</span>                  </p>
</body>
</html>
